

def extract_materials_info(data):

    materials_list = []
    for video in data.get('materials', {}).get('videos', []):
        video_id = video.get('id')
        path = video.get('path')
        if path:
            # 提取文件名（去除路径和扩展名）
            filename = path.split('/')[-1].split('.')[0]
            materials_list.append({
                'id': video_id,
                'material_name': filename
            })

    return materials_list
